package EjercicioExamen;

import java.util.HashMap;

public class Comercial {

	private HashMap<String,Producto> prodList = new HashMap<String,Producto>();
	private String name;
	
	public Comercial(String comName) {
		prodList.clear();
		name = comName;
	}
	
	public void AddProduct(String prodName, Producto prod) {
		prodList.put(prodName,prod);
	}
	
	public Producto GetProduct(String prodName) {
		return prodList.get(prodName);
	}
	
	public void ClearProdList() {
		prodList.clear();
	}
	
	public void EraseProdFromList(Producto prod) {
		prodList.remove(prod);
	}
	
	public int GetProdNum() {
		return prodList.size();
	}
	
	public String GetName() {
		return name;
	}
	
}
